<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<link rel="stylesheet" type="text/css" href="css/edittable.css"></link>
<link rel="stylesheet" type="text/css" href="css/validate.css"></link>
<script type="text/javascript" src="js/jquery-1.8.0.js"></script>
<title>My JSP 'index.jsp' starting page</title>

<script>
	/*function checkRoleName() {
		var result = true;
		var reg = /^.{2,15}$/;
		var roleName = $("#roleName").val();
		if (!reg.test(roleName)) {
			$("#roleName_msg").html("角色名格式错误! ").css("color", "red");
			result = false;
		} else {
			$.ajax({
				url : "RoleServlet.do?flag=check",
				type : "POST",
				data : {
					roleName : roleName
				},
				async : false,//必须写要不然有可能没判断完这个方法已经运行完了,就会出现用户名重复但是能提交
				success : function(data) {
					if ("0" == data) {
						result = false;
						$("#roleName_msg").html("角色名重复!").css("color", "red");
					}

				},
			});
		}
		if (result == true) {
			$("#roleName_msg").html("验证通过").css("color", "green");
		}
		return result;
	}*/
		//管理员修改是无法修改账号的因此不需要做验证
	function checkAll() {
		return confirm("确定要提交吗");
	}

	$(function() {

		$("input[type=text],textarea").focus(function() {
			$(this).addClass("input_focus");
		}).blur(function() {
			$(this).removeClass("input_focus");
		});

		$(".form_btn").hover(function() {
			$(this).css("color", "red").css("background", "#6FB2DB");
		},

		function() {
			$(this).css("color", "#295568").css("background", "#BAD9E3");
		});

		/*$("#roleName").focus(function() {
			$("#roleName_msg").html("2-15位,非空白字符").css("color", "#8FA0AC");
		}).blur(checkRoleName);*/
	});
</script>

<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">


<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">

<meta http-equiv="description" content="This is my page">
<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
</head>

<body>
	<div class="div_title">
		<div class="div_titlename">
			<img src="images/san_jiao.gif"><span>管理员修改</span>
		</div>
	</div>

	<form action="AdminServlet.do?flag=adminModify&adminId=${param.adminId}"
		method="post">
		<table class="edit_table">
			<tr>
				<td class="td_info">角色名称:</td>
				<td class="td_input_short"><input type="text" class="txtbox"
					id="adminName" name="adminName" value="${param.adminName}" readonly="readonly" /></td>
				<td><label class="validate_info" id="adminName_msg">用户账号无法修改</label>
				</td>
			</tr>


			<tr>
				<td class="td_info">备注信息:</td>
				<td><textarea rows="4" cols="27" name="note" id="note"
						class="txtarea">${param.note}</textarea></td>
				<td><label></label></td>
			</tr>
			<tr>
				<td class="td_info"></td>
				<td><input class="form_btn" type="submit" value="提交"
					onclick="return checkAll()" /> <input type="reset" class="form_btn"
					value="重置" /></td>
				<td><label id="result_msg" class="result_msg">${msg}</label></td>
			</tr>
		</table>
	</form>
</body>
</html>